<?php

class IndexController extends Zend_Controller_Action
{

    public function init()
    {
        /* Initialize action controller here */
    }

    public function indexAction()
    {
    	echo '<h1>Index action</h1><br>';
    }
	public function bookAction()
	{
		$page1 = array(   array('id'=>'1','title'=>'PHP'),
				array('id'=>'2','title'=>'PHP 5'),
				array('id'=>'3','title'=>'Zend Framework'),
		);
		$page2 = array(   array('id'=>'4','title'=>'Javascript'),
				array('id'=>'5','title'=>'JQuery'),
				array('id'=>'6','title'=>'Javascript Framework'),
		);
		$page3 = array(   array('id'=>'7','title'=>'HTML'),
				array('id'=>'8','title'=>'CSS'),
				array('id'=>'9','title'=>'ASP'),
		);
		$book = array('1'=>$page1,
				'2'=>$page2,
				'3'=>$page3);
		$page = $this->_request->getParam('page',1);
		$this->view->book = $book[$page];
		
		$this->_helper->layout->disableLayout();
		//$this->_helper->viewRenderer->setNoRender();
	}

}

